A Fuzzy Logic-Based Directional Charging Scheme for Wireless Rechargeable Sensor Networks

Wireless Power Transfer (WPT) has become a key technology to extend network lifetime in Wireless Rechargeable Sensor Networks (WRSNs). The traditional omnidirectional recharging method has a wider range of energy radiation, but it inevitably results in more energy waste. By contrast, the directional recharging mode enables most of the energy to be focused in a predetermined direction that achieves higher recharging efficiency. However, the MC (Mobile Charger) in this mode can only supply energy to a few nodes in each direction. Thus, how to set the location of staying points of the MC, its service sequence and its charging orientation are all important issues related to the benefit of energy replenishment. To address these problems, we propose a Fuzzy Logic-based Directional Charging (FLDC) scheme for Wireless Rechargeable Sensor Networks. Firstly, the network is divided into adjacent regular hexagonal grids which are exactly the charging regions for the MC. Then, with the help of a double-layer fuzzy logic system, a priority of nodes and grids is obtained that dynamically determines the trajectory of the MC during each round of service, i.e., the charging sequence. Next, the location of the MC’s staying points is optimized to minimize the sum of charging distances between MC and nodes in the same grid. Finally, the discretized charging directions of the MC at each staying point are adjusted to further improve the charging efficiency. Simulation results show that FLDC performs well in both the charging benefit of nodes and the energy efficiency of the MC.


Introduction
In Wireless Sensor Networks (WSNs), a large number of cheap microsensor nodes are deployed in a specific area to form a multi-hop and self-organized network for monitoring [1].However, due to the limited battery capacity of nodes, the network is always energy-constrained.That is to say, when some nodes die, an energy hole will inevitably appear which has a significant impact on the functionality of the network [2].
Fortunately, Kurs et al. [3] demonstrated that energy can be transferred between magnetically resonant coils in a strongly coupled regime, and a number of Wireless Power Transfer (WPT) techniques have been developed, such as magnetic resonant coupling, inductive coupling, and electromagnetic radiation [4].By utilizing the WPT technology to provide wireless, reliable, and continuous energy supply for sensors, it promotes the development of Wireless Rechargeable Sensor Networks (WRSNs) which has a wide range of research prospects for wearable devices [5], access control authentication [6] and Industrial Internet of Things [7,8].
In WRSNs, one or more Mobile Chargers (MCs) are responsible for supplying energy to nodes periodically or on demand [9].Obviously, nodes which will run out of energy should be replenished in time.Thus, it is particularly important for the MC to set an appropriate order to serve nodes, which is regarded as the "charging scheduling problem" [10].
Sensors 2024, 24, 5070 2 of 31 There are mainly two types of charging scheduling schemes in WRSNs, i.e., periodical charging [11] and on-demand charging [12,13].In the former mode, the MC periodically replenishes energy to nodes, and the duration for a round of charging can be either fixed or adjustable.During each round, the MCV sets off from the Base Station (BS) and traverses some nodes in a predefined order to recharge them.Finally, it goes back to the BS for a quick battery replacement and prepares for the next round of recharging services.Obviously, this charging method is simple and easy to implement, but it cannot adapt to changes in energy demand of nodes.In on-demand charging, the charging request is sent out when a node's energy falls below a certain threshold.This request is placed into the service queue of the MC according to a predetermined priority [14].When receiving the recharging requests from nodes, the MCV departs from the BS as soon as possible and starts its energy replenishment service.Then, it recharges these nodes according to the calculated order and returns to the BS when its residual energy is insufficient.Obviously, this mode is more suitable for WRSNs, but it is always a key issue to set the priority of nodes being replenished.
In addition, according to different mechanisms of energy radiation, the replenishment mode for the MC can also be categorized into omnidirectional charging and directional charging.An MC with omnidirectional WPT broadcasts electromagnetic waves equally in all directions.Since the radiated energy fades rapidly over distance, chargers might require excessively high transmission power to supply enough energy to nodes.By contrast, in directional charging mode, energy can be concentrated in a narrow beam for transmission, which greatly improves the charging efficiency in WRSNs [15].However, in most of the existing works, charging orientations of the MC are simply determined by the geometric location of each node as well as the energy radiation region of the MC.It does not consider dynamic information such as the residual energy or the charging demand of nodes, which is precisely one of the problems that we need to solve in this paper.
To address the issues raised above, we propose a Fuzzy Logic-based Directional Charging (FLDC) scheme.As we all know, fuzzy logic systems are flexible, user friendly, easy to understand, and an important tool for decision-making, so they can be very helpful for dynamic charging scheduling planning [16,17].The main contributions of this paper are summarized as follows.

•
Considering the fact that the MC often charges directionally in each discrete orientation at each staying point, the network in FLDC is divided into a number of virtual grids.Then, to ensure that nodes can be fairly recharged, we propose a method for setting the priorities of each grid based on a two-layer fuzzy logic system.Thus, a reasonable order for the MC to traverse each staying point is obtained.

•
In addition, the locations of the staying points are further optimized based on the gradient descent method.This shortens the average distance between the nodes to be recharged and the MC, thus effectively reducing the energy loss during charging.

•
Based on the priority of nodes to be recharged, each discrete charging direction of the MC as well as the rotational order of its charge orientations at each staying point are sequentially calculated.Furthermore, to balance the energy receiving efficiency of each node within the same energy radiation range, the charging direction of the MC is fine-tuned, thereby effectively shortening the charging duration.

Periodic Charging and On-Demand Charging
In periodic charging, the MC usually replenishes energy to nodes following a fixed trajectory round by round.Obviously, in a scenario where the energy consumption rate of nodes is constant, this model has some advantages.That is, once the path for the MC to charge nodes is established, it does not need to be generated again.Xie et al. [18] considered a scenario where mobile chargers periodically visit all nodes in a sensor network and charge them to achieve sustainable network operation.They proposed a pre-optimized TSP-based charging protocol to achieve this goal.However, this may lead to unnecessary visits to nodes with sufficient energy.This not only increases the movement distance of the MC, but also may prolong the waiting time for nodes that urgently need to be recharged.To address this issue, Hu et al. [19] proposed an efficient slot-based periodic charging time scheduling algorithm.They adopted a fine-grained node classification scheme to prevent unnecessary visits to energy-sufficient nodes.Moreover, a balanced charging task assignment scheme was also used in this method to avoid charging starvation.
To avoid node deaths, many periodic charging methods assume that the MC has sufficient or even an infinite amount of energy, but this is not realistic.For this reason, Huong et al. [20] proposed a periodic charging scheme for WRSNs with the goal of minimizing the number of dead nodes, considering the limited battery capacity of the MC.In addition, they presented a two-phase algorithm to obtain an optimal charging path for the MC, as well as the charging duration for each node.In one of our previous works [21], a periodic and distributed energy supplementation method was proposed with the help of a ring-based cost-balanced data uploading strategy.It performs well at enhancing the proportion of live nodes as well as the wireless recharging efficiency.Moreover, Lyu et al. [22] divided the network into multiple cells, and the MC periodically traverses each cell with the objective of maximizing the amount of data collected as well as its charging efficiency.
Relatively speaking, the on-demand charging mode is more adaptable to large-scale networks.Quan et al. [23] introduced an on-demand charging scheme based on Q-learning, which maximizes the survival rate of nodes while ensuring network connectivity as well as sensing coverage.Locations of all the critical nodes are calculated, and they are then recharged in a way that improves the performance of the whole network.Similarly, in [24], locations of all nodes that can be served in time are first calculated.Next, the most appropriate charging duration for various staying points can be obtained.This ensures that the next node being recharged by the MC is always the optimal target.In addition, Lin et al. [25] proposed a temporal-spatial real-time charging scheduling algorithm (TSCA) for the on-demand charging mode to prolong network lifetime by maximizing recharging efficiency.TSCA achieved feasible solutions by using node insertion and deletion algorithms based on their locations relative to the MC and the subsequent node.
Recent research increasingly focuses, in on-demand charging mode, on dividing the network into several areas to allow multiple MCs to supply energy to nodes in a distributed manner, thereby improving energy efficiency.Lin et al. [26] proposed a dual warning threshold with dual preemption (DWDP) charging scheme, which uses dual warning thresholds to adjust the charging priority of different sensors when the residual energy level of a sensor node is lower than a certain threshold.Then, DWDP is extended to the scenario of multiple mobile chargers, and a cooperative charging method CCDWDP is proposed.Tomar et al. [27] thought that most of the on-demand charging schemes leave out the contemplation of multiple network attributes while making scheduling decisions and even overlook the issue of ill-timed charging response to nodes with uneven energy consumption rates.Thus, they proposed a fuzzy logic-based charging scheduling method that assigns the MCs to k different regions.Furthermore, the dynamic recharging threshold is individually set for each node.However, collaboration among multiple MCs is not considered in this method.Yang et al. [28] proposed a multi-type charging scheduling strategy based on the difference of area requirement.The network is divided into inner and outer regions.Nodes in the inner region form a flat topology, and a periodic and one-to-one charging mode is adopted by a mobile charger to maintain a high survival rate of nodes.In Sensors 2024, 24, 5070 4 of 31 contrast, nodes located in the outer region form several clusters, and multiple UAVs supply energy to these nodes in a one-to-many manner to achieve higher energy efficiency.

Omnidirectional Charging and Directional Charging
Nowadays, the omnidirectional charging mode is widely adopted in scenarios with dense node deployment.Ma et al. [29] proposed a solution to the problem of maximizing charging utility when multiple nodes are charging simultaneously.The main constraint is the battery capacity of the mobile charger.They also studied the problem of minimizing the length of an MC's movement path under the assumption that all nodes which require charging can be recharged and the mobile charger has sufficient energy to do so.To address the problem of slow wireless charging speed affecting network operational efficiency, Xu et al. [30] proposed a many-to-many energy replenishment strategy based on the omnidirectional charging mode.Experimental results show that this method effectively shortens the waiting duration for nodes to be recharged.Dande et al. [31] proposed an efficient energy recharge scheduling for MCs, aiming to maximize the spatial and temporal surveillance qualities (STSQs) of the given network.Firstly, the network is partitioned to distribute the MC's charging load evenly.Then, the sensors adjust the sensing rate frequency to manage their energy.Finally, cooperation between the neighboring MCs is proposed to reduce the waiting time for recharging requested sensors.However, they did not provide further explanation on how to balance the workload of multiple MCs.
Compared to omnidirectional charging, the energy radiation model of directional charging is more realistic.Thus, more and more researchers have studied the charging scheduling problem based on the directional charging mode.Wang et al. [32] proposed a radio-frequency-based WPT in which a base station with multiple directional antennas is responsible for charging nodes.However, in this model, the position of the base station is fixed, so it cannot be applied to large-scale networks.In [33], Lee et al. proposed an energyefficient directional charging (EEADC) algorithm that considers the density of sensor nodes to adaptively choose one-to-one or one-to-many charging modes.With the help of directional antennas, the optimal charging orientation for an MC can be calculated out in EEADC, thereby minimizing its energy loss during the charging process.Gao et al. [34] pointed out that the existing research neglects cooperative energy re-distribution (ERD) among nodes for energy charging efficiency.Therefore, they focused on the scenario of charging a WRSN using a directional mobile charger and addressed the underlying ERD-assisted directional charging schedule problem.Moreover, Wu et al. [35] studied cooperative scheduling for directional charging with spatial occupation.They formulated a cooperative charging scheduling model with spatial occupation problem of mobile rechargeable sensor devices for optimizing the total cost of charging the whole system.
Unlike the above studies that deployed only a single type of MC, the deployment of a mixture of directional and omnidirectional mobile chargers is considered by Lin et al. [36].They proposed a method that can find the minimum number of chargers needed to cover all the sensor nodes.Moreover, the energy radiation power of the charger is also taken into consideration when determining the traversal position of the MC.Wang et al. [37] proposed an Average Energy Charging (AEC) algorithm.Firstly, directed coverage subsets of the network with large increases in charging utility are selected.Then, locations of staying points as well as the movement path of the MC can be obtained with the help of these subsets.Next, the charging duration during a round of service is evenly distributed to each coverage subset to balance the charging utility of them.In addition, they further proposed a Maximum Utility Charging (MUC) algorithm to improve the performance of AEC by assigning an appropriate charging duration to each subset based on the energy replenishment requirement of nodes located in this region.
The related work presented above is summarized in Table 1.

•
Both AEC and MUC adopt a periodic charging scheduling method, which is consistent with the service mode of the MC proposed in this paper;

•
Both AEC and MUC address issues such as determining the charging orientation of the MC, forming several coverage subsets to enable the MC to perform one-to-many charging in order, path planning, etc., which are also the focus of this paper.

Network Model
Assuming that N nodes (each of them is denoted as S i (i∈ [1, N])) are randomly deployed in a rectangular network with length L and width W. Each of the nodes is equipped with a magnetically coupled coil that can be wirelessly recharged, and all of them have full battery capacity, i.e., E s , at the beginning of the network running time.The base station is located at any fixed position within the network, and it is responsible for the following tasks.

•
Collecting and processing all the sensing data.

•
Scheduling and controlling the energy replenishment behavior of each MC.

•
Replacing the battery for MCs with insufficient residual energy.
The network model is shown in Figure 1.
There are N MC MCs in the network (the calculation process of N MC is described in Section 4.1), and they replenish energy to each node in the form of magnetic coupling resonance.Each MC possesses a maximum battery capacity of E MC , and its wireless energy radiation range is shown as the fan-shaped region in Figure 2. R c and θ refer to "the farthest reachable charging distance" and "the charging angle of expansion" of the MC, respectively.The values of them are determined by the physical hardware properties of the MC.
In Figure 2, → CO j indicates the orientation of the current wireless charging radiation region of the j-th MC, i.e., the direction of the angle bisector of the fan-shaped area in this figure.→ MC j , s i is the direction vector formed between the MC and the node s i within its charging range.The angle between the above two vectors is denoted as α ji .Therefore, Sensors 2024, 24, 5070 6 of 31 according to the wireless charging energy receiving model described in [38], the energy receiving power p r (s i ) of s i when it is replenished by MC j is represented as follows.
In this formula, d(MC j , s i ) represents the distance between MC j and s i being recharged by it.The parameters c, µ and β are constants which are determined by the experimental environment and the hardware parameters of chargers.η is the energy receiving power coefficient of the node when the MC performs "zero distance-based wireless recharging" on it.
Sensors 2024, 24, x FOR PEER REVIEW 6 of 3 base station is located at any fixed position within the network, and it is responsible fo the following tasks.

•
Collecting and processing all the sensing data.

•
Scheduling and controlling the energy replenishment behavior of each MC.

•
Replacing the battery for MCs with insufficient residual energy.The network model is shown in Figure 1.There are NMC MCs in the network (the calculation process of NMC is described in Section 4.1), and they replenish energy to each node in the form of magnetic coupling resonance.Each MC possesses a maximum battery capacity of EMC, and its wireles energy radiation range is shown as the fan-shaped region in Figure 2. Rc and θ refer to "the farthest reachable charging distance" and "the charging angle of expansion" of th MC, respectively.The values of them are determined by the physical hardware propertie of the MC.
In Figure 2, j CO indicates the orientation of the current wireless charging radiation region of the j-th MC, i.e., the direction of the angle bisector of the fan-shaped area in thi figure.i j s MC , is the direction vector formed between the MC and the node si within it charging range.The angle between the above two vectors is denoted as αji.Therefore according to the wireless charging energy receiving model described in [38], the energy receiving power p r (si) of si when it is replenished by MCj is represented as follows.
( ) With the bottom left corner of the network as the origin of the rectangular coordinate system and Rc as the radius, the network is divided into several adjacent regular hexagons called "Virtual Grid, VG", as shown in the dashed range in Figure 1 Obviously, if MCj stays at the center of a VG, its charging orientation j CO only needs to be rotated a maximum of   θ π 2 times to achieve wireless energy replenishment for all nodes located within this VG.The VG with its center located inside the network is called "Non-boundary Virtual Grid, NB-VG" (as shown by the regular hexagon with a blue background in Figure 1), and the nodes located inside it are called "Non-boundary nodes, NB nodes".Similarly, the VG centered outside the network is referred to as the "Boundary Virtual Grid, B-VG" (as shown by the regular hexagon with a yellow background in Figure 1), and the nodes located within the B-VG are referred to as "Boundary nodes, B-nodes".
According to their task queues, the MCs are enabled to replenish energy to nodes as required.The execution process is described as follows.

•
For nodes located in NB-VG (i.e., NB-node), the MC adopts a "move-stay-rotate-move" approach to supply energy to the corresponding nodes with a maximum wireless charging radius of Rc.That is, when MCj reaches a staying point of a NB-VG (the initial location of the staying point is the geometric center of each NB-VG, which may be optimized in the future, as detailed in Section 5.3), it provides energy to the corresponding nodes through multiple rotations of j CO according to their distribution, as depicted by MC1 in Figure 3. Subsequently MCj moves to the next staying point.

•
For nodes in B-VG (i.e., B-node), the MC will perform a "zero distance-based wireless charging" strategy in a "one-to-one" way, and it leaves this B-VG only after serving all the nodes that need to be replenished in it, as shown by MC2 in Figure 3.With the bottom left corner of the network as the origin of the rectangular coordinate system and R c as the radius, the network is divided into several adjacent regular hexagons called "Virtual Grid, VG", as shown in the dashed range in Figure 1.Obviously, if MC j stays at the center of a VG, its charging orientation → CO j only needs to be rotated a maximum of Sensors 2024, 24, 5070 ⌈2π/θ⌉ times to achieve wireless energy replenishment for all nodes located within this VG.The VG with its center located inside the network is called "Non-boundary Virtual Grid, NB-VG" (as shown by the regular hexagon with a blue background in Figure 1), and the nodes located inside it are called "Non-boundary nodes, NB nodes".Similarly, the VG centered outside the network is referred to as the "Boundary Virtual Grid, B-VG" (as shown by the regular hexagon with a yellow background in Figure 1), and the nodes located within the B-VG are referred to as "Boundary nodes, B-nodes".
According to their task queues, the MCs are enabled to replenish energy to nodes as required.The execution process is described as follows.

•
For nodes located in NB-VG (i.e., NB-node), the MC adopts a "move-stay-rotate-move" approach to supply energy to the corresponding nodes with a maximum wireless charging radius of R c .That is, when MC j reaches a staying point of a NB-VG (the initial location of the staying point is the geometric center of each NB-VG, which may be optimized in the future, as detailed in Section 5.3), it provides energy to the corresponding nodes through multiple rotations of → CO j according to their distribution, as depicted by MC 1 in Figure 3. Subsequently, MC j moves to the next staying point.

•
For nodes in B-VG (i.e., B-node), the MC will perform a "zero distance-based wireless charging" strategy in a "one-to-one" way, and it leaves this B-VG only after serving all the nodes that need to be replenished in it, as shown by MC 2 in Figure 3.
required.The execution process is described as follows.
• For nodes located in NB-VG (i.e., NB-node), the MC adopts "move-stay-rotate-move" approach to supply energy to the corresponding node with a maximum wireless charging radius of Rc.That is, when MCj reaches staying point of a NB-VG (the initial location of the staying point is the geometri center of each NB-VG, which may be optimized in the future, as detailed in Sectio 5.3), it provides energy to the corresponding nodes through multiple rotations o j CO according to their distribution, as depicted by MC1 in Figure 3. Subsequentl MCj moves to the next staying point.

•
For nodes in B-VG (i.e., B-node), the MC will perform a "zero distance-base wireless charging" strategy in a "one-to-one" way, and it leaves this B-VG only afte serving all the nodes that need to be replenished in it, as shown by MC2 in  These two different energy replenishment strategies are adopted in FLDC due to th following two reasons.These two different energy replenishment strategies are adopted in FLDC due to the following two reasons.

•
Most of the areas of the NB-VG are within the network; that is to say, there are many nodes located in each of these NB-VGs.These nodes are distributed in some circles whose centers are the geometric centers of the NB-VGs, and the radius of these circles is R c .Thus, after the MC has continuously radiated energy in different directions at a fixed staying point for a period of time, the energy requirement of all the corresponding nodes in this NB-VG can be satisfied.Obviously, this "one-to-many" wireless charging mode can effectively shorten the movement distance of the MC and ensure its high energy efficiency to a certain extent.In addition, the most suitable radiation direction of the MC at each staying point (the area with the yellow background shown in Figure 3) can be obtained by the discretization method (please see the description in Section 5.4 for details), so that inefficient and ineffective charging behavior can be avoided as much as possible, thereby further improving service efficiency.• There are only a few nodes in the area of B-VG.Thus, "zero distance-based one-to-one wireless charging" is adopted, which can minimize energy loss without increasing the movement distance of the MC too much.Furthermore, the amount of data generated by these B-nodes located at the edge of the network is significantly less than that of NBnodes (especially those near the base station).Thus, for the former, the frequency of being recharged is relatively low, which weakens the negative impact of this charging mode to some extent.
It should be noted that the proposed FLDC method can be applied to networks of any shape and scale due to the fact that the network is divided into "virtual hexagons" (hereinafter referred to as "grids") that is consistent with the omnidirectional energy radiation range of the MC.For convenience of description, we only use a square network as an example to illustrate.Definitions of parameters of the network model are shown in Table 2.

Parameter Settings and Problem Description 4.1. Number of MCs in the Network
In order to adapt to networks with different scales, multiple MCs are allowed to supply energy to each node in a distributed manner in FLDC.Therefore, the value of N MC needs to be determined at first.According to the description in Section 3, the upper limit value of the energy consumed by an MC for charging all nodes in an NB-VG k (denoted as E c (NB-VG k )) can be expressed as follows.Without loss of generality, it is assumed that the energy of each node is recharged from zero to E s .
In Formula (2), NoN(NB-VG k ) represents the number of nodes in this non-boundary grid, and p c (MC) is the energy transmission power (i.e., the charging power) of the MC.It should be pointed out that "cos(θ/2)" in the denominator of Formula ( 2) is the minimum value of cosα ji in Formula (1).In this case, s i is exactly located on the radius of the fan-shaped energy radiation range of the MC.Thus, the maximum energy consumed by an MC to charge all NB-nodes in the network during a round of service time (denoted as E c max (NB-VG)) can be expressed as follows.
In Formula (3), Num(NB-VG) is the number of NB-VGs which have nodes in need of recharging.
Similarly, the energy E c (B-VG k ) consumed by an MC to charge all nodes in a B-VG k from zero to full energy E s can be expressed as follows.
Here, NoN(B-VG k ) is the number of nodes in the boundary grid B-VG k .Hence, the maximum energy consumed by an MC to charge all B-nodes in the network during a round of service time (denoted as E c max (B-VG)) can be expressed by Formula (5).Similarly, Num(B-VG) here is the number of B-VGs which have nodes in need of recharging.
Furthermore, during a round of charging, the energy consumed by the MC on moving, i.e., E m (NB-VG), is shown as follows.Here, d VG represents the average distance that the MC moves between two adjacent grids (the base station is also regarded as the center of a grid), and e m is the energy consumption of the MC on moving per unit of distance.
The energy consumption of an MC moving within all the B-VGs which have nodes in need of recharging can be expressed by Formula (7).
In addition, is the distance between two adjacent B-nodes (i.e., s i and s i+1 ) that are sequentially traversed by the MC.In summary, if inequality (9) holds, it can ensure that the charging demand of all nodes in the network can be met.E MC here is the maximum amount of energy that an MC can carry.
Thus, the number of MCs needed in the network can be calculated out by Formula (10).

Maximum Duration T max for a Single MC to Finish a Round of Service
As mentioned above, in FLDC, the MCs periodically recharge each node.Due to the limited amount of energy carried by each MC, we first discuss the maximum duration of a round of energy replenishment.
When assigning the charging task to N MC MCs, it can be considered that the number of NB-VG and B-VG that each MC can serve in a round of traversal time is Num(NB-VG)/N MC and Num(B-VG)/N MC , respectively.Therefore, the upper limit values of the duration for an MC to charge all nodes in NB-VG and B-VG that it can serve (denoted as T c max (NB-VG) and T c max (B-VG), respectively) can be expressed as follows.
In Formula ( 11), d MC j , s i represents the mean distance between all NB-nodes and the center of the NB-VG they are located in (i.e., the staying point of MC j in this NB-VG).It should be pointed out that if the average number of nodes in each NB-VG (denoted as n NB-VG ) is less than the maximum number of directions that the MC can charge at each staying point (marked as ⌈2π/θ⌉), it indicates that there are no nodes in the area covered by certain charging directions of the MC.Obviously, in this case, the MC only needs to perform a period of n NB-VG charging at these staying points at most.Otherwise, a period of ⌈2π/θ⌉ energy replenishment process should be carried out.The value of n NB-VG is calculated by Formula (13).
Moreover, Formula ( 14) shows the expression of the time spent on moving during a round of energy replenishment service, in which v is the speed of the MC. And, Therefore, the periodic recharging process of each MC can be carried out smoothly if and only if Formula ( 16) holds.

Problem Description
The objective of FLDC is to design a flexible and adaptive dynamic charging scheduling scheme for the network model mentioned above as well as the energy replenishment plan of the MC in traversing each NB-VG and B-VG, so as to maximize the efficiency of all nodes in the network.Hence, the charging benefit of node s i (denoted as U c (s i )) is defined as follows. 1.
In Equation ( 17), µ(s i ) represents the proportion of "the extended lifetime of s i after being recharged once" to "the maximum lifetime it can survive without being recharged".That is, p(si) is the energy consumption rate of si, and tr(si) represents its residual lifetime at the moment before the MC starts to charge it.Namely, In (19), tw(si) represents the active duration of si from the last time it has been recharged to the current moment.

2.
The definition of σ(s i ) in Formula ( 17) is shown as follows. And, ) and min(t c (s j )|j∈[1, N]) represent the longest and the shortest charging time of all nodes being recharged, respectively.It is easy to see that when the following three conditions are met simultaneously, the time spent on charging s j is the longest.
• The distance between s j and the staying point is exactly R c ; • s j is located at the edge of the fan-shaped energy radiation range of the MC; • s j is recharged from no energy to its full energy capacity, E s .That is, Without loss of generality, we assume that the amount of energy supplied to any node s j should no less than 2T max × p(s j ) every time, which means that the extended lifetime of s j after being recharged must be at least equal to the longest time interval between the two services provided by the MC to it.Thus, the following equation holds.
It is not difficult to find that σ(si) reflects the approximation degree between the duration of one charge of si and the longest charging duration among all nodes during this round.

3.
In (17), ε is an adjustment coefficient, with a value between 0 and 1.When its value is close to 1, the extended lifetime of s i after being recharged is the main indicator to show its charging efficiency.That is, the larger the value, the higher the charging efficiency of s i .On the contrary, when ε is close to zero, the duration of a single charge for s i has a greater impact on its charging efficiency.That is, the smaller the value, the higher the charging efficiency of s i .
At this point, the objective and constraints of FLDC can be described as follows.Definitions of parameters in this section are shown in Table 3.

Method Description
To maximize the charging efficiency of nodes in a "one-to-many wireless energy supply mode with rotatable charging direction", the following three tasks are carried out by FLDC.Firstly, with the help of a two-layer fuzzy logic system, the priority of each grid can be obtained, which reasonably determines the order in which the MC traverses each staying point, ensuring the fairness of nodes being recharged.Subsequently, the gradient descent method is adopted to optimize the position of each staying point, which shortens the average distance between nodes in need of recharging and the MC, effectively reducing energy loss during the charging process.Finally, based on the priority level of nodes being replenished, the discrete energy radiation directions (charging direction angles) as well as the rotation order of the MC at each staying point are determined in sequence.Furthermore, with the goal of balancing the energy receiving efficiency of each node, fine adjustment of charging directions is made to shorten the overall charging time.

Priority of Node and Grid Based on Two-Layer Fuzzy Logic
In FLDC, the attributes of s i at any time can be characterized by its residual lifetime t r (s i ), energy consumption rate p(s i ), and the distance from the center of the grid (marked as d(s i , center k )) it belongs to.Obviously, nodes with a smaller value of t r (s i ) or a larger value of p(s i ) should be prioritized for energy replenishment as much as possible.In addition, the distance between the center of a grid and the current position of the MC (denoted as d(center k , MC j )) also has a significant impact on its traversal order.To address this, we construct a two-layer fuzzy logic system using the aforementioned attributes to determine a reasonable node-charging priority, and subsequently the traversal order of each grid.
Fuzzy logic is a method of decision-making that utilizes human thinking and reasoning.The system calculates fuzzy inputs and provides outputs ranging from 0 to 1 [39].In this section, we use t r (s i ), p(s i ) and d(s i , center k ) as inputs to the first layer of the fuzzy logic system to obtain the Node Priority (NP) of nodes being charged in each grid.Then, NP and d(center k , MC j ) are regarded as the inputs to the second layer of this system to obtain the Grid Priority (GP) of each grid being traversed.
The trapezoidal and triangular membership functions are adopted in the proposed fuzzy logic system.Namely, Here, x is the clear input, and x 1 -x 4 is the coordinate range of the membership function of the fuzzy variable.
The three types of input language values and membership function ranges in the first layer of the system are shown in Table 4, and the system output is shown in Table 5.Here, max(p(s i )) represents the node with the highest energy consumption rate among all nodes participating in the calculation.In addition, the value of d(s i , center k ) clearly does not exceed R c .Similarly, the value of t r (s i ) will not exceed 2T according to the trigger conditions of the MC mentioned in Section 5.2.The input-output functions of the fuzzy logic system in this layer are shown in Figure 4.It can be seen that by transforming the clear inputs into fuzzy inputs through membership functions, three types of membership degrees of nodes regarding this attribute can be obtained.Then, the fuzzy inputs can be transformed into fuzzy outputs according to the IF-THEN rule.The first layer of the fuzzy logic system has three types of inputs and one type of output, with a total of twenty-seven rules, as shown in Table 6.Without loss of generality, nodes with lower residual lifetimes and higher energy consumption rates will have higher priority, as the output of rule R7 shows.On the contrary, the priority of nodes with higher residual lifetimes and lower energy consumption rates is relatively lower, as the output of rule R19 shows.The fuzzy output of the above two membership functions are calculated as follows.
The fuzzy output of the above two membership functions are calculated as follows.
With the help of the fuzzy input function, three fuzzy output membership degrees can be calculated out.By taking the minimum value for each rule mentioned above, the corresponding fuzzy output for each rule can be obtained.Then, we take the maximum linguistic value for each output to obtain the modified membership function image for each node.
Subsequently, the centroid-based deblurring method is adopted to obtain the deblurring points.The fuzzy output is transformed into a clear one, and then different expected values are sampled and averaged.The sum of the contributions of each sample point to the overall membership degree is calculated as the current priority.Assuming that µ(Z p ) is the modified membership function of the fuzzy output set, and Num is the number of points on the modified output that extends along the x-axis, then In this way, the priority of each node in the current set of nodes to be recharged can be obtained in a range from zero to one.The larger the value, the higher the priority.Without loss of generality, the highest NP value of all nodes in each grid is considered as the unified NP value of nodes in that grid and is used as an input into the second layer of the fuzzy logic system.In addition, the distance between the center of each grid and the current position of the MC (d(center k , MC j )) is also input.From this, the input-output rules and membership functions of the second layer can be obtained, as shown in Tables 7 and 8. Here, max(NP(s i )) represents the highest value of NP among all nodes participating in the calculation, while max(d(center k , MC j )) is the maximum distance between the center of each grid and the current position of the MC.The input and output functions of the fuzzy logic system in this layer are shown in Figure 5.The calculation rules for the second layer of fuzzy logic are shown in Table 9. Obviously, if the grid is closer to the current position of the MC and the value of its NP(si) is high at this time, it will obtain a higher priority of being traversed in the future, as shown in rule R5.On the contrary, if the grid is far away from the MC and its NP(si) is low, its traversal order will be later, as rule R11 shows.

Grid Priority-Based Charging Process of the MC
According to the description in Section 5.1, the priority of each grid being traversed at any time can be obtained with the help of the double-layer fuzzy logic system.Thus, the charging process of the MC in FLDC is described as follows.
Step 1.When the network has been deployed, the base station continuously monitors the status of all nodes.If the residual lifetime of any node (i.e., t r (si)) decreases to Tmax, IDs of nodes whose t r (si) is less than 2Tmax are put into the "set of nodes to be recharged".This set is denoted as Qnode, and it is initially empty.Afterwards, the BS will perform the above operation once every Tmax interval.As described in Section 4.2, Tmax is defined as the maximum duration required for a single MC to complete a round of energy replenishment.That is to say, for any node that MC is about to serve in this round, as long as it can survive for at least Tmax time from the departure time of the MC, it can ensure that it will not die and can be successfully replenished before the MC arrives.Furthermore, it is not difficult to see that nodes with a lifetime of less than 2Tmax at this moment probably need to be recharged during the next two rounds of MC traversal (otherwise they may die).Therefore, the above settings are selected.
Step 2. The priority of each grid corresponding to the nodes in Qnode are calculated The calculation rules for the second layer of fuzzy logic are shown in Table 9. Obviously, if the grid is closer to the current position of the MC and the value of its NP(s i ) is high at this time, it will obtain a higher priority of being traversed in the future, as shown in rule R5.On the contrary, if the grid is far away from the MC and its NP(s i ) is low, its traversal order will be later, as rule R11 shows.

Grid Priority-Based Charging Process of the MC
According to the description in Section 5.1, the priority of each grid being traversed at any time can be obtained with the help of the double-layer fuzzy logic system.Thus, the charging process of the MC in FLDC is described as follows.
Step 1.When the network has been deployed, the base station continuously monitors the status of all nodes.If the residual lifetime of any node (i.e., t r (s i )) decreases to T max , IDs of nodes whose t r (s i ) is less than 2T max are put into the "set of nodes to be recharged".This set is denoted as Q node , and it is initially empty.Afterwards, the BS will perform the above operation once every T max interval.As described in Section 4.2, T max is defined as the maximum duration required for a single MC to complete a round of energy replenishment.That is to say, for any node that MC is about to serve in this round, as long as it can survive for at least T max time from the departure time of the MC, it can ensure that it will not die and can be successfully replenished before the MC arrives.Furthermore, it is not difficult to see that nodes with a lifetime of less than 2T max at this moment probably need to be recharged during the next two rounds of MC traversal (otherwise they may die).Therefore, the above settings are selected.
Step 2. The priority of each grid corresponding to the nodes in Q node are calculated with the help of the two-layer fuzzy logic system.
Step 3.Each MC located at the base station selects a grid with the highest priority in sequence as its target to serve, and the ID of each node in it to be recharged is deleted from Q node .Then, MC j moves from the BS to the corresponding grid.If the target of MC j is an NB-VG, it just moves to its staying point.If it is a B-VG, MC j needs to move to the node with the highest value of NP in it.
Step 4. After arriving at the grid, MC j will serve all the nodes which are located in it and waiting to be recharged according to the method described in Section 3.That is, if its charging objects are NB-nodes, MC j rotates its charging orientation in a discrete way to achieve a "one-to-more" charging.Otherwise, the "zero distance-based one-to-one wireless recharging" mode will be adopted.
Step 5.If Q node = Ø when MC j completes serving all the nodes in a grid (marked as VG k ), it indicates that there are no nodes waiting to be recharged in the network at this time.In this case, it returns to the base station, and the algorithm jumps to step 6 for execution.Otherwise, it selects the grid with the highest priority (marked as VG k+1 ) corresponding to the nodes in Q node at this time.Subsequently, MC j judges whether it can continue to traverse the next grid according to ( 29) and (30).If both inequalities hold true, MC j deletes the IDs of nodes to be recharged in VG k+1 from Q node , and then moves to this grid to serve these nodes.After completing these tasks, the judgment of this step will be carried out again until it returns back to the base station.
E r (MC j ) and T(MC j ) are the residual energy of MC j and the duration during which it has served in this round, respectively.d(k, k + 1) and d(k + 1, BS) represent the distance between the k-th grid (current grid) and the (k + 1)-th grid (the next grid MC j intends to traverse), as well as the distance between the (k + 1)-th grid and the base station, respectively.Moreover, the energy and time that MC j is expected to consume in serving the (k + 1)-th grid are marked as E c (VG k+1 ) and T c (VG k+1 ), respectively.Thus, the following two conclusions can be drawn.

•
If the grid is an NB-VG, the value of E c (VG k+1 ) can be estimated by Formula (2).Moreover, the value of T c (VG k+1 ) in Formula ( 30) can be expressed by (31), in which N c (NB-VG k+1 ) represents the number of nodes waiting to be recharged in the grid.
• If the grid is B-VG, Formula (4) is used to estimate the value of E c (VG k+1 ).In this case, the value of T c (VG k+1 ) in (30) should be calculated using Formula (32).Here, the number of nodes waiting to be recharged in the grid is denoted as NoN c (B-VG k+1 ).
Step 6.When MC j returns back to the BS, its battery will be replaced.If Q node ̸ = Ø at this moment, the grid with the highest priority corresponding to the nodes in Q node is selected with the help of the two-layer fuzzy logic system again.Then, the algorithm jumps to step 3 to start a new round of charging service.Otherwise, MC j stays at the BS until Q node is not empty again, and then the above steps are carried out once more.

Optimization of the Location of Staying Points (OLSP) for Minimizing the Sum of Charging Distance
As mentioned above, the staying points of the MC in each NB-VG are initially set at their geometric centers.However, due to the random distribution of nodes in the grid, this position may not be the "best staying point".For example, in Figure 6, there are only three nodes (s i , s j , s k ) waiting to be recharged in NB-VG k .Obviously, if the staying point of the MC is set to the centroid of ∆s i s j s k , the charging effect is inevitably better than that being set to the geometric center P of NB-VG k .The reason is that the energy receiving power p r (s i ) is almost inversely proportional to the value of d(MC j , s i ) as a square term according to Formula (1).In addition, as described in Section 5.2, the IDs in Q node often change, which means that even for the same grid, the nodes served by the MC may not be exactly the same each time.
sors 2024, 24, x FOR PEER REVIEW being set to the geometric center P of NB-VGk.The reason is that the ener power p r (si) is almost inversely proportional to the value of d(MCj, si) as a according to Formula (1).In addition, as described in Section 5.2, the IDs change, which means that even for the same grid, the nodes served by the be exactly the same each time.In summary, it is necessary to optimize the location of each staying po by the MC in each round of the recharging process.The specific steps are follows.
Step 1.When the MC is about to traverse grid NB-VGk, the follow describing the sum of distances between the staying point SPk and nodes lo it and waiting to be recharged can be obtained.The coordinates of SPk and are denoted as (xk, yk) and (x(si), y(si)), respectively, and the former is geometric center of NB-VGk.
Step 2. The gradient of D(NB-VGk) relative to the location of the cur point (xk, yk) is calculated, as shown in Formula (34).
Obviously, the value of D(NB-VGk) can be minimized by adjusting the po staying point in the opposite direction of the gradient.
Step 3. The possible updated coordinate (xk (j+1) , yk (j+1) ) of the staying poin is calculated using Formula (35).Here, j represents the number of times this been updated, and (xk (0) , yk (0) ) is just (xk, yk).Moreover, η represents the step movement during this adjustment process, and D(NB-VGk) (j+1) represents the In summary, it is necessary to optimize the location of each staying point traversed by the MC in each round of the recharging process.The specific steps are described as follows.
Step 1.When the MC is about to traverse grid NB-VG k , the following function describing the sum of distances between the staying point SP k and nodes located within it and waiting to be recharged can be obtained.The coordinates of SP k and any node s i are denoted as (x k , y k ) and (x(s i ), y(s i )), respectively, and the former is initially the geometric center of NB-VG k .
Step 2. The gradient of D(NB-VG k ) relative to the location of the current staying point (x k , y k ) is calculated, as shown in Formula (34).

∇D(NB-VG
Obviously, the value of D(NB-VG k ) can be minimized by adjusting the position of this staying point in the opposite direction of the gradient.
Step 3. The possible updated coordinate (x k (j+1) , y k (j+1) ) of the staying point in the grid is calculated using Formula (35).Here, j represents the number of times this position has been updated, and (x k (0) , y k (0) ) is just (x k , y k ).Moreover, η represents the step size for each movement during this adjustment process, and D(NB-VG k ) (j+1) represents the result of the j-th calculation of gradient.
Step 4. We judge whether the following three conditions are met if the location of the staying point is updated to (x k (j+1) , y k (j+1) ).If so, the staying point of this grid is moved along the direction of the gradient mentioned above to the updated coordinate calculated in Formula (35).Next, the value of j is updated to j + 1, and then the algorithm jumps to the third step to continue optimizing the location of the staying point.Otherwise, (x k (j+1) , y k (j+1) ) is taken as the final result of the position of this staying point.
• The first condition.For any node waiting to be recharged in NB-VG k , the distance between it and the updated staying point does not exceed the upper limit value of the wireless charging distance, i.e., R c .That is to say, inequality (36) holds.
x(s i ) − x • The second condition.The distance between the two staying points after the j-th and (j−1)-th adjustments is greater than the threshold δ, meaning that Formula (37) is valid. x • The third condition.The number of adjustments j has not reached the upper limit.

Determining the Charging Directions Based on the Discretization Method
After the OLSP has been executed, the location of the staying point in each grid should be as close as possible to the nodes waiting to be recharged.However, according to the output mechanism of the first layer of the fuzzy logic system described in Section 5.1, even within the same grid, the priority of each node being recharged often varies.In addition, we need to further determine the direction of energy radiation as well as the rotation sequence of the MC's charging orientation.Therefore, the process of "Determining the Charging Directions" (DCD) is described as follows.
Step 1. Nodes whose IDs are in Q node are sorted in a descending order of their NP in NB-VG k to form a queue Q(NB-VG k ).Obviously, the length of this queue is N c (NB-VG k ).
Step 2. A polar coordinate system is established with (x k , y k ) as the pole.Thus, the polar coordinates of those N c (NB-VG k ) nodes mentioned above can be calculated.That is, for any s i pending recharge in NB-VG k , its polar coordinate can be expressed as (d(SP k , s i ), φ i ).
Step 3. The direction vector → SP k s i from the staying point to the first node in Q(NB-VG k ) is taken as the initial orientation of MC j 's first energy radiation range.Then, IDs of nodes located in this fan-shaped area are put into C 1 which is defined as the set of nodes being covered by MC j in this orientation.According to Formula (1), it can be seen that in the case where d(MC j , s i ) is fixed, p r (s i ) can reach its maximum value if and only if α ji is zero.Therefore, the purpose of this is to ensure that the node with the highest NP in Q(NB-VG k ) as well as its neighbor can be efficiently and preferentially recharged.
Step 4. The IDs that were already in C 1 are deleted from Q(NB-VG k ).Then, if Q(NB-VG k ) is not empty at this time, the algorithm goes to the third step and iteratively executes it to form the next cover set C2, C3, etc. Otherwise, the execution process of DCD ends, and the discrete charging directions of MC j in NB-VG k and the respective cover sets can be obtained.It should be pointed out that there may be overlap between those fan-shaped regions, but any node will only be recharged once during An example of the execution process of DCD is described as follows.As shown in Figure 7a, there are eight nodes in NB-VG k , and six of them are waiting to be recharged (red dots).The NPs of all these nodes have been calculated.Without loss of generality, we Q(NB-VG k ) = {s 1 , s 2 , s 3 , s 4 , s 5 , s 6 }, and SP k is the staying point of this grid obtained by the OLSP algorithm.It can be seen that after carrying out the DCD algorithm, the charging direction vectors all point to the node with the highest value of NP covered by the corresponding energy radiation area.Although this can maximize the value of p r (si), it may affect the effectiveness of other nodes being served.For example, in Figure 7a, due to ( ) here is taken as the weight of φi of each node in Cp associated with SPk.That is, the final orientation of the MC when serving nodes in Cp will be more inclined towards the node that is farther away from it.Figure 8 shows the final charging directions as well as the radiation range of the MC located at SPk after the above corrections.It is not difficult to see from both Figure 8a,b that these charging directions take into account the fairness of node recharge efficiency in the covered area.This shortens the charging and staying duration of the MC, which improves its service efficiency.It should be noted that there is only one node s3 covered by the third energy radiation range (as shown in Figure 8c).Thus, there is no need to modify the charging direction of the MC in this case.So, → SP k s 1 is regarded as the initial direction vector of the first energy radiation range of MC j .It can be seen from Figure 7a that both s 4 and s 6 are located within the fan-shaped charging area corresponding to this orientation.Thus, C 1 = {s 1 , s 4 , s 6 }, and the IDs in Q(NB-VG k ) are now updated to {s 2 , s 3 , s 5 }.Subsequently, → SP k s 2 is set as the initial direction vector of the second charging range, as shown in Figure 7b, and it is easy to see that s 5 is covered by it, that is, C 2 = {s 2 , s 5 }.Similarly, → SP k s 3 is marked as the initial direction vector of the third energy radiation range of MC j , and now C 3 = {s 3 }, as shown in Figure 7c.
It can be seen that after carrying out the DCD algorithm, the charging direction vectors all point to the node with the highest value of NP covered by the corresponding energy radiation area.Although this can maximize the value of p r (s i ), it may affect the effectiveness of other nodes being served.For example, in Figure 7a, due to ∠ → SP k s 1 → SP k s 4 being large and the distance between s 4 and SP k being relatively far, the value of p r (s 4 ) is lower.To further balance the charging efficiency among nodes in the same set, the charging direction of the MC needs to be fine-tuned, which is named "Determining the Charging Directions after Adjustment" (DCD_A).The final direction vector → SP k C p for MC j to charge nodes in the set C p at SP k can be expressed by Formula (38).
2 here is taken as the weight of φ i of each node in C p associated with SP k .That is, the final orientation of the MC when serving nodes in C p will be more inclined towards the node that is farther away from it.Figure 8 shows the final charging directions as well as the radiation range of the MC located at SP k after the above corrections.It is not difficult to see from both Figure 8a,b that these charging directions take into account the fairness of node recharge efficiency in the covered area.This shortens the charging and staying duration of the MC, which improves its service efficiency.It should be noted that there is only one node s 3 covered by the third energy radiation range (as shown in Figure 8c).Thus, there is no need to modify the charging direction of the MC in this case.
Therefore, when the MC traverses to any NB-VG k , it will supply energy to nodes one by one according to the order constructed by the DCD method, with fine-tuned results for its charging directions as mentioned above.
above corrections.It is not difficult see from both Figure 8a,b that these char directions take into account the fairness of node recharge efficiency in the covered This shortens the charging and staying duration of the MC, which improves its se efficiency.It should be noted that there is only one node s3 covered by the third en radiation range (as shown in Figure 8c).Thus, there is no need to modify the char direction of the MC in this case.

Simulation Results
In order to verify the performance of FLDC, a series of simulations are carried out to show the charging utility and energy utilization ratio of the MC as well as the charging duration.Three methods, BASE, BASE + OLSP, and BASE + DCD_A are selected as the comparison algorithms.

•
BASE is the benchmark method for FLDC in which the MC only stays at the geometric center when traversing each NB-VG (the OLSP is not carried out), and the charging orientation of the MC is not adjusted (no DCD_A is performed).

•
BASE + OLSP and BASE + DCD_A are the variations of BASE that include the "optimization of the location of staying point" and "determining the charging directions after adjustment", respectively.
We also compare FLDC with two typical directional charging scheduling algorithms, AEC and MUC, on a number of dead nodes, energy consumption and movement distance of the MC during a round of charging time, and the node charging utility.Parameter settings of the simulation are shown in Table 10.It should be noted that, for all methods, if not specified, each node served by the MC must be recharged to its full battery capacity, i.e., Es.

Impact of the Adjustment Coefficient ε on Charging Utility
As above, maximizing the energy replenishment efficiency in directional charging mode is the main purpose of FLDC.Thus, the result of U c (s i ) for BASE, BASE + OLSP, BASE + DCD_A, and FLDC with different values of ε are analyzed first.Without loss of generality, we present the average value of U c (s i ) of all nodes (marked as U c (s i )) in each method in Figure 9.
the value of ( ) i c s U in BASE + DCD_A is only slightly higher than that in means that only adjusting the charging direction of the MC without o staying position cannot significantly improve the charging utility.This is be achieves the goal of "shortening the maximum charging duration of node energy radiation area of an MC" by fine-tuning the charging orientation.degree of improvement in μ(si) and decrease in σ(si) of other nodes is limite In contrast, the average charging utility in BASE + OLSP is relatively hig same as that in FLDC.The reason is that optimizing the location of each effectively shortens the distance between MC and nodes, thereby greatly e energy receiving efficiency of nodes and shortening the charging duration.In Figure 9, the values of U c (s i ) for all the four methods increase with increasing ε, but the gap between them continues to narrow.According to Formula (17), the larger the ε, the higher the proportion of µ(s i ) in the fraction of its molecule.For this reason, the value of U c (s i ) also increases and continuously approaches one.Regardless of the value of ε, the charging utility in BASE is the lowest one among the four methods, with the difference being more pronounced when ε is small.This is because it does not optimize the MC's staying point location nor its charging direction, resulting in small values of µ(s i ) and relatively large values of σ(s i ) for each node.Moreover, it is not difficult to find that the value of U c (s i ) in BASE + DCD_A is only slightly higher than that in BASE, which means that only adjusting the charging direction of the MC without optimizing its staying position cannot significantly improve the charging utility.This is because DCD_A achieves the goal of "shortening the maximum charging duration of nodes within each energy radiation area of an MC" by fine-tuning the charging orientation.However, the degree of improvement in µ(s i ) and decrease in σ(s i ) of other nodes is limited in this case.In contrast, the average charging utility in BASE + OLSP is relatively high, almost the same as that in FLDC.The reason is that optimizing the location of each staying point effectively shortens the distance between MC and nodes, thereby greatly enhancing the energy receiving efficiency of nodes and shortening the charging duration.
Figure 10 shows the average charging utility with different Energy Replenishment Requirements (ERR).It is known from Figure 9 that regardless of the value of ε, the charging utility of BASE is relatively close to that of BASE + DCD_A.Similarly, the difference of U c (s i ) between BASE + OLSP and FLDC is also not significant.Therefore, we only show the charging utility of BASE + DCD_A and FLDC in Figure 10 to describe the variation more clearly.
Figure 10 shows the average charging utility with different Energy Replenishment Requirements (ERR).It is known from Figure 9 that regardless of the value of ε, the charging utility of BASE is relatively close to that of BASE + DCD_A.Similarly, the difference of ( ) i c s U between BASE + OLSP and FLDC is also not significant.Therefore, we only show the charging utility of BASE + DCD_A and FLDC in Figure 10 to describe the variation more clearly.It can be seen from Formula ( 17) that when ε = 0.1, the U c (s i ) of each node mainly depends on the "duration of a single charge for s i ", as shown in Figure 10a.In this case, recharging each node to its full battery capacity will undoubtedly result in a low value of U c (s i ).As shown in Figure 10a, the average charging utility of nodes in FLDC at this time is only approximately 53.53%, and the value in BASE + DCD_A is even lower at 35.91%.When ERR is reduced, both methods show a significant increase in U c (s i ).
In the case that ε = 0.6, the average charging utility of a node mainly depends on the "its lifetime that can be extended after being recharged once", as shown in Figure 10b.When ERR is low, µ(s i ) is small, leading to a low value of U c (s i ).In contrast, a higher ERR results in a larger µ(s i ), which enhances the node's charging utility.In Figure 10b, when the energy replenished to nodes is increased from 40%E s to E s , values of U c (s i ) in both methods rise by more than 10%.
Furthermore, regardless of the values of ε and ERR, the average charging utility in FLDC is always higher than that in BASE + DCD_A (e.g., when ε = 0.1 or 0.6, the former is approximately 17% or 9% higher than the latter, respectively), which is due to the OLSP carried out by FLDC.

Impact of θ on Energy Utilization Ratio and Charging Utility
During the process of directional charging, the charging angle of expansion θ not only determines the range of energy the MC radiates and the number of nodes it can serve each time, but also affects the energy reception effect of nodes.Therefore, the performance of the system with different values of θ is analyzed here.To accurately demonstrate the effect of θ on node energy utilization ratio (defined as the proportion of energy received by a node to the energy radiated by the MC for charging it) as well as the average value of node charging utility, the furthest charging distance (R c ) and the energy transmitting power (p c (MC)) of the MC are set to 3.5 m and 10 w, respectively.We mainly show the experimental results in a single NB-VG.
As shown in Figure 11a, in the BASE method, regardless of the number of nodes within each NB-VG, a smaller θ results in a higher energy utilization ratio for the nodes.This is because when θ is small, the deviation between → CO j and the location of the node being recharged is relatively small.That is to say, α ji in Formula (1) is small in this case, ensuring that p r (s i ) can reach a larger value.On the contrary, if θ is larger, the energy of the MC is radiated over a wider area, which undoubtedly affects the energy utilization of some nodes located at the edge of this region.As illustrated in Figure 11a, the average energy utilization ratio of the nodes in BASE is only about 20% when θ = π, which is much lower than that of θ = π/6 (58-62%).
being recharged is relatively small.That is to say, αji in Formula ( 1) is small in this case, ensuring that p r (si) can reach a larger value.On the contrary, if θ is larger, the energy of the MC is radiated over a wider area, which undoubtedly affects the energy utilization of some nodes located at the edge of this region.As illustrated in Figure 11a, the average energy utilization ratio of the nodes in BASE is only about 20% when θ = π, which is much lower than that of θ = π/6 (58-62%).Figure 11b demonstrates the node energy utilization ratio for different values of θ in FLDC.It is evident that when there is only one node in an NB-VG, the value of θ does not affect the energy utilization effect of the node, with its average energy utilization ratio reaching up to 90%.According to the algorithm execution process described in Section 5.3, in this case, the MC will adjust its staying position within the NB-VG to the vicinity of the node, almost achieving zero distance-based wireless charging, which results in a higher energy utilization ratio.As the number of nodes in the NB-VG increases, the overall charging utility of all nodes should be taken into account when determining the locations of the MC's staying points.That is to say, the charging mode will be changed from "zero distance-based one-to-one charging" to "spaced distance-based one-to-many charging", leading to a decrease in the energy utilization ratio of the nodes.The larger the θ, the more pronounced the decrease.However, with the same number of nodes in an NB-VG, the energy utilization ratio of FLDC is higher than that of BASE with each value of θ.This indicates the effectiveness of OLSP and DCD_A in our method.
Figure 12 demonstrates the effect of different values of θ on the average value of charging utility for the four methods, i.e., BASE, BASE + OLSP, BASE + DCD_A, and FLDC.In order to make the results more distinguishable, we keep the average number of nodes within each NB-VG to two, and the value of ε is set to 0.1 (as previously mentioned, the charging utility of nodes is mainly determined by their charging duration).It is easy to see from the figure that when θ = π/6, the values in all these four methods are high and almost equal to each other.As θ increases, the charging utility decreases in each method.It can be seen from Figure 11 that a larger value of θ results in a lower average energy utilization ratio of nodes within the MC's coverage area.To achieve the energy replenishment target, the MC's charging duration increases in this case, which undoubtedly reduces the charging utility of nodes.However, the charging utility of FLDC and BASE + OLSP decreases relatively slowly, which is also due to the fact that they both optimize the locations of staying points in the gird, thus shortening the node's charging duration compared to BASE and BASE + DCD_A under the same conditions.
energy utilization ratio of nodes within the MC's coverage area.To achieve the energy replenishment target, the MC's charging duration increases in this case, which undoubtedly reduces the charging utility of nodes.However, the charging utility of FLDC and BASE + OLSP decreases relatively slowly, which is also due to the fact that they both optimize the locations of staying points in the gird, thus shortening the node's charging duration compared to BASE and BASE + DCD_A under the same conditions.

Variation in the Charging Duration of Nodes
Figure 13a illustrates the charging duration reduction ratio (CDRR for short) for BASE before and after DCD_A have been performed.In order to minimize the impact of nodes with extremely poor positions on simulation results, we randomly initialized the distribution of nodes multiple times and carried out multiple experiments at θ = 2π/3 to display the average value of the results.As can be seen from this figure, when the

Variation in the Charging Duration of Nodes
Figure 13a illustrates the charging duration reduction ratio (CDRR for short) for BASE before and after DCD_A have been performed.In order to minimize the impact of nodes with extremely poor positions on simulation results, we randomly initialized the distribution of nodes multiple times and carried out multiple experiments at θ = 2π/3 to display the average value of the results.As can be seen from this figure, when the number of nodes in an NB-VG is less than three, the charging duration is not shortened.In this case, the number of nodes that the MC can cover in each energy radiation direction is almost no more than one.Thus, according to the description in Section 5.4, there is no need to perform DCD_A to fine-tune the charging direction of the MC at this time.When the number of nodes ranges from four to eight, the average charging duration is reduced by about 10%.This is due to the fact that the DCD_A realizes the fine-tuning of the charging range by setting the weight coefficients relative to the current charging direction of the MC.This makes its final charging direction slightly biased towards nodes farther away from it, which reduces the difference in the duration that each node is recharged to a certain extent.It can be seen that in the case of five nodes, the value of CDRR has increased by nearly 30%, indicating a significant effect after executing DCD_A.number of nodes in an NB-VG is less than three, the charging duration is not shortened.In this case, the number of nodes that the MC can cover in each energy radiation direction is almost no more than one.Thus, according to the description in Section 5.4, there is no need to perform DCD_A to fine-tune the charging direction of the MC at this time.When the number of nodes ranges from four to eight, the average charging duration is reduced by about 10%.This is due to the fact that the DCD_A realizes the fine-tuning of the charging range by setting the weight coefficients relative to the current charging direction of the MC.This makes its final charging direction slightly biased towards nodes farther away from it, which reduces the difference in the duration that each node is recharged to a certain extent.It can be seen that in the case of five nodes, the value of CDRR has increased by nearly 30%, indicating a significant effect after executing DCD_A.Figure 13b shows the average charging duration reduction ratio of nodes after performing BASE + OLSP, BASE + DCD_A, and FLDC, compared to the BASE method.The parameter settings are the same as those in Figure 13a, and the results of BASE are also displayed as the benchmark in this figure for ease of comparison.It is not difficult to see that the average value of CDRR after performing BASE + OLSP or FLDC is reduced by about 40-60%, compared to that of BASE.This is because they both optimize the Figure 13b shows the average charging duration reduction ratio of nodes after performing BASE + OLSP, BASE + DCD_A, and FLDC, compared to the BASE method.The parameter settings are the same as those in Figure 13a, and the results of BASE are also displayed as the benchmark in this figure for ease of comparison.It is not difficult to see that the average value of CDRR after performing BASE + OLSP or FLDC is reduced by about 40-60%, compared to that of BASE.This is because they both optimize the staying position of the MC by performing OLSP, making it closer to nodes.When the number of nodes in an NB-VG ranges from one to three, the effect of this optimization is more significant.As the number of nodes increases, even after optimization, it is unlikely that the staying point is close to each node at the same time.In this case, the value of CDRR in BASE + OLSP and FLDC is reduced (maintained at around 40%).Since BASE + OLSP does not further execute DCD_A, its effect is slightly inferior to that of FLDC.

Performance Comparison between Different Directional Charging Algorithms
In order to further demonstrate the advantages of FLDC, we compare it with AEC, MUC, and BASE in terms of the number of dead nodes, the energy consumption and movement distance of the MC during a round of charging, and the charging utility.Experimental results are shown in Figures 14-17.
Sensors 2024, 24, x FOR PEER REVIEW 27 of 3 number of them is 120 or 160).In addition, both AEC and MUC take the node to be replenished as the staying point, and they construct the "set of nodes to be recharged" successively with the purpose of "maximizing the overall charging utility".Therefore compared with BASE, the staying points in these two methods are closer to nodes to be recharged, which makes the number of dead nodes lower than that of BASE.However unlike our method that uses a two-layer fuzzy logic-based approach to set the grid priority and the traversal order of the MC, in AEC and MUC, the MC always traverse the staying points along the shortest path and the charging duration of each round is the same.This may result in some nodes with low residual energies dying since they canno be recharged in time.For this reason, the number of dead nodes in AEC and MUC i higher than that in FLDC, and the difference is more pronounced when the number o nodes is higher.It should be pointed out that for ease of execution, the staying duration of the MC in each "set of nodes to be recharged" is set to the same value in AEC, which is obviously unable to satisfy the nodes' different energy replenishment needs.On the other hand, the MUC method reasonably allocates the staying duration of the MC in set so its number of dead nodes is lower than that of AEC.  Figure 15 verifies the energy consumption of the MC after completing a round o service using each algorithm.For the sake of comparison, normalization is performed here to only show the proportion of the average energy consumed by the MC in a single round to its full energy capacity EMC (hereafter referred to as the "energy consumption proportion").It is not difficult to see that in BASE, the staying point of the MC in each number of them is 120 or 160).In addition, both AEC and MUC take the node to be replenished as the staying point, and they construct the "set of nodes to be recharged" successively with the purpose of "maximizing the overall charging utility".Therefore, compared with BASE, the staying points in these two methods are closer to nodes to be recharged, which makes the number of dead nodes lower than that of BASE.However, unlike our method that uses a two-layer fuzzy logic-based approach to set the grid priority and the traversal order of the MC, in AEC and MUC, the MC always traverses the staying points along the shortest path and the charging duration of each round is the same.This may result in some nodes with low residual energies dying since they cannot be recharged in time.For this reason, the number of dead nodes in AEC and MUC is higher than that in FLDC, and the difference is more pronounced when the number of nodes is higher.It should be pointed out that for ease of execution, the staying duration of the MC in each "set of nodes to be recharged" is set to the same value in AEC, which is obviously unable to satisfy the nodes' different energy replenishment needs.On the other hand, the MUC method reasonably allocates the staying duration of the MC in set, so its number of dead nodes is lower than that of AEC.  Figure 15 verifies the energy consumption of the MC after completing a round of service using each algorithm.For the sake of comparison, normalization is performed here to only show the proportion of the average energy consumed by the MC in a single round to its full energy capacity EMC (hereafter referred to as the "energy consumption proportion").It is not difficult to see that in BASE, the staying point of the MC in each increases, the number of grids that need to be traversed by the MC also rises, so the movement distance of the MC in FLDC becomes longer.As for BASE, the MC is likely to have no extra energy left to serve more nodes at this point (e.g., as can be seen in Figure 15, the proportion of energy consumed by the MC in BASE was close to 90% when the number of nodes reaches 200).As a result, the gap between the simulation results of BASE and FLDC increases when the number of nodes is high.Figure 17 demonstrates the variation of charging utility with the number of node when ε = 0.6.To show the fairness of this comparison, the charging utility after carryin out AEC and MUC is also calculated using Formula (17).Simulation results show that th charging utility in FLDC or BASE is significantly higher than the other two methods an is not affected by the number of nodes.This is because, after obtaining the grid priorit with the help of the two-layer fuzzy logic system, the MC in both FLDC and BASE ca supply more energy to nodes, which results in a larger value of μ(si), thus ensuring higher charging utility.After executing OLSP and DCD_A, the average charging duratio of FLDC is less than that of BASE, so the charging utility of the former is slightly highe (by about 13%) than the latter.
Due to the fact that AEC and MUC are not like FLDC and BASE in which the MC only charges nodes with shorter residual lifetime, their charging utility is relatively low Furthermore, the average charging utility of AEC is lower than that of MUC.This i because the stay duration of the MC is always fixed in AEC, which is unable to adapt t different charging demands of nodes as in MUC.In addition, there are more and mor "sets of nodes to be recharged" in AEC and MUC as the number of nodes increases Nevertheless, the charging duration is always fixed in these two methods, which ma lower the value of μ(si).Thus, the average charging utility of AEC and MUC decreases a the number of nodes increases.Figure 14 shows the number of dead nodes in these four methods with different numbers of nodes.Since BASE only sets the traversal order of the MC without further optimizing its staying position and charging direction, there is a high number of dead nodes in this method.On the contrary, FLDC further performs OLSP and DCD_A on the basis of BASE, ensuring a high survival rate of nodes (almost no nodes die when the number of them is 120 or 160).In addition, both AEC and MUC take the node to be replenished as the staying point, and they construct the "set of nodes to be recharged" successively with the purpose of "maximizing the overall charging utility".Therefore, compared with BASE, the staying points in these two methods are closer to nodes to be recharged, which makes the number of dead nodes lower than that of BASE.However, unlike our method that uses a two-layer fuzzy logic-based approach to set the grid priority and the traversal order of the MC, in AEC and MUC, the MC always traverses the staying points along the shortest path and the charging duration of each round is the same.This may result in some nodes with low residual energies dying since they cannot be recharged in time.For this reason, the number of dead nodes in AEC and MUC is higher than that in FLDC, and the difference is more pronounced when the number of nodes is higher.It should be pointed out that for ease of execution, the staying duration of the MC in each "set of nodes to be recharged" is set to the same value in AEC, which is obviously unable to satisfy the nodes' different is less than that of BASE, so the charging utility of the former is slightly higher (by about 13%) than the latter.

Conclusions
Due to the fact that AEC and MUC are not like FLDC and BASE in which the MC only charges nodes with shorter residual lifetime, their charging utility is relatively low.Furthermore, the average charging utility of AEC is lower than that of MUC.This is because the stay duration of the MC is always fixed in AEC, which is unable to adapt to different charging demands of nodes as in MUC.In addition, there are more and more "sets of nodes to be recharged" in AEC and MUC as the number of nodes increases.Nevertheless, the charging duration is always fixed in these two methods, which may lower the value of µ(s i ).Thus, the average charging utility of AEC and MUC decreases as the number of nodes increases.

Conclusions
In this paper, we propose a fuzzy logic-based directional charging scheduling scheme to improve the charging efficiency in WRSNs.Firstly, the charging areas for the MC at each staying point are determined by dividing the network into hexagons.Next, the priority of nodes as well as hexagons is dynamically calculated every time to enable the MC to select the next staying point in order.To minimize the sum of the charging distance, a method for optimization of the location of staying points is proposed.Finally, the charging directions of the MC at each staying point are fine-tuned to balance the charging duration of nodes in the same coverage set.Simulation results show that the proposed method can effectively improve the charging utility as well as the survival rate of nodes compared with other methods of the same type.
Considering the fact that the attributes of sensing nodes are not necessarily fixed in practical situations, in our future work, we will consider dynamic changes of sensing nodes, such as the movement of node position, the change of node energy consumption rate with sensing events, etc., so that our algorithms can be more closely matched with practical applications.We will also consider adding new nodes to the charging queue to improve the energy utilization if the MC capacity is sufficient during a round of charging.

Figure 2 .
Figure 2. Energy radiation range of the MC.

Figure 2 .
Figure 2. Energy radiation range of the MC.

Figure 2 .
Figure 2. Energy radiation range of the MC.

Figure 4 .
Figure 4. Input and output function of the first layer.(a) Residual lifetime; (b) energy consumption rate; (c) distance between nodes and the center of grid; (d) node priority.

Figure 4 .
Figure 4. Input and output function of the first layer.(a) Residual lifetime; (b) energy consumption rate; (c) distance between nodes and the center of grid; (d) node priority.

Figure 5 .
Figure 5. Input and output function of the second layer.(a) Distance between center of grid and MC; (b) node priority; (c) grid priority.

Figure 5 .
Figure 5. Input and output function of the second layer.(a) Distance between center of grid and MC; (b) node priority; (c) grid priority.

Figure 6 .
Figure 6.Location of the staying point before and after optimization.(a) the staying p geometric center of NB-VGk.(b) the staying point is the centroid of Δsisjsk.

Figure 6 .
Figure 6.Location of the staying point before and after optimization.(a) the staying point is the geometric center of NB-VG k .(b) the staying point is the centroid of ∆s i s j s k .

Sensors 2024 ,Figure 7 .
Figure 7. Process of determining the initial charging directions.

∠for
being large and the distance between s4 and SPk being relatively far, the value of p r (s4) is lower.To further balance the charging efficiency among nodes in the same set, the charging direction of the MC needs to be fine-tuned, which is named "Determining the Charging Directions after Adjustment" (DCD_A).The final direction vector MCj to charge nodes in the set Cp at SPk can be expressed by Formula(38).

Figure 8 .
Figure 8. Final charging directions and the radiation ranges of the MC.(a) modify the first charging

Figure 7 .
Figure 7. Process of determining the initial charging directions.

Figure 8 .
Figure 8. Final charging directions and the radiation ranges of the MC.(a) modify the first cha direction of the MC.(b) modify the second charging direction of the MC.(c) the third cha direction of the MC doesn't need to be corrected.

Figure 8 .
Figure 8. Final charging directions and the radiation ranges of the MC.(a) modify the first charging direction of the MC.(b) modify the second charging direction of the MC.(c) the third charging direction of the MC doesn't need to be corrected.

Figure 9 .
Figure 9. Charging utility under different values of ε.

Figure 10 6 Figure 10 .
Figure 10 shows the average charging utility with different Energy R Requirements (ERR).It is known from Figure 9 that regardless of the v charging utility of BASE is relatively close to that of BASE + DCD_A.difference of ( ) i c s U between BASE + OLSP and FLDC is also not significa we only show the charging utility of BASE + DCD_A and FLDC in Figure the variation more clearly.

Figure 9 .
Figure 9. Charging utility under different values of ε.

6 Figure 10 .
Figure 10.Charging utility with different energy replenishment requirements.Figure 10.Charging utility with different energy replenishment requirements.

Figure 10 .
Figure 10.Charging utility with different energy replenishment requirements.Figure 10.Charging utility with different energy replenishment requirements.

Figure 11 .
Figure 11.Energy utilization ratio under different values of θ and different numbers of nodes.

Figure 12 .
Figure 12.Charging utility with different values of θ.

Figure 12 .
Figure 12.Charging utility with different values of θ.

Figure 13 .
Figure 13.Charging duration of nodes in different methods.(a) Charging duration after performing DCD_A; (b) charging duration in four methods.

Figure 13 .
Figure 13.Charging duration of nodes in different methods.(a) Charging duration after performing DCD_A; (b) charging duration in four methods.

Figure 14 .
Figure 14.Number of dead nodes in different algorithms.

Figure 15 .
Figure 15.Average proportion of energy consumed by the MC in different algorithms.

Figure 14 .
Figure 14.Number of dead nodes in different algorithms.

Figure 14 .
Figure 14.Number of dead nodes in different algorithms.

Figure 15 .
Figure 15.Average proportion of energy consumed by the MC in different algorithms.

Figure 15 .
Figure 15.Average proportion of energy consumed by the MC in different algorithms.

Figure 16 . 3 Figure 16 .
Figure 16.Movement distance of MC during a round of charging.

Figure 17 .
Figure 17.Average charging utility with number of nodes.

Figure 17 .
Figure 17.Average charging utility with number of nodes.

Table 2 .
Parameters of the network.
j , s i ) distance between MC j and s i m η energy receiving power coefficient of node in "zero distance-based wireless recharging" mode -

Table 3 .
Parameters mentioned in Section 4.
d B-VG (i, i + 1)distance between two adjacent B-nodes (i.e., s i and s i+1 ) that are sequentially traversed by the MC m T max maximum duration for a single MC to finish a round of service s T c max (NB-VG) the upper limit values of the duration for an MC to charge all nodes in an NB-VG s T c max (B-VG) the upper limit values of the duration for an MC to charge all nodes in a B-VG s T m the time an MC spends on moving during a round of service s d MC j , s i the mean distance between all NB-nodes and the center of the NB-VG they are located in m w (s i ) the active duration of s i from the last time it has been recharged to the current moment s

Table 4 .
Linguistic value and ranges of membership functions of the first layer.

Table 5 .
Output value of the first layer.

Table 6 .
Fuzzy inference rules for the first layer.

Table 6 .
Fuzzy inference rules for the first layer.

Table 8 .
Output value of the second layer.

Table 9 .
Fuzzy inference rules for the second layer.

Table 9 .
Fuzzy inference rules for the second layer.